import request from '@/util/uploadFileRequest'

export function uploadUserSingleFile(fileInput,data) {
    const formData = new FormData()
    formData.append('file', fileInput)
    formData.append('appendData', JSON.stringify(data))
    return request({
        url: '/user-file/upload',
        method: 'post',
        data: formData
    })
}

export function uploadAdminSingleFile(fileInput,data) {
    const formData = new FormData()
    formData.append('file', fileInput)
    formData.append('appendData', JSON.stringify(data))
    return request({
        url: '/admin/resource/upload',
        method: 'post',
        data: formData
    })
}

